//
//  TestModel.m
//  XHLKit
//
//  Created by qinyulun on 16/6/17.
//  Copyright © 2016年 leTian. All rights reserved.
//

#import "TestModel.h"
#import "MJExtension.h"

@interface TestModel()<MJKeyValue>

@end

@implementation TestModel

+ (instancetype) modelWithDic:(NSDictionary *)dic
{
    TestModel *model = [[self class] new];
    [model setValuesForKeysWithDictionary:dic];
    return model;
}

- (void)setValue:(id)value forUndefinedKey:(NSString *)key
{
    if ([key isEqualToString:@"id"]) {
        self.creatId = value;
    }
}

- (NSDictionary *)replacedKeyFromPropertyName
{
    NSDictionary *dic = @{@"creatId":@"id"};
    return dic;
}

@end
